import requests
from lxml import etree
url = 'http://127.0.0.1:8080/index.html'


ret = requests.get(url=url).text
tree = etree.HTML(ret)
img_url = tree.xpath('//*[@id="myCarousel"]/div/div[1]/a/img/@src')[0]
a = 'http://127.0.0.1:8080' + img_url[(img_url.find('.')+1):]
print(a)
# http://127.0.0.1:8080/img/widget-banner01.png
